HelpCandsColors = [
    "#00FA92",
    "#0096FF",
    "#FF9300",
    "#FF40FF",
    "#479FD3",
    # "#0355F1",
    "#00F900",
    "#945200",
    "#9437FF",
]

# HelpCellsColors = HelpCandsColors
HelpCellsColors = [
    "#CCFFFF",
    "#FFFCCC",
    "#CDFFCC",
    "#FFCCCC",
    "#CCE6FF",
    "#E8FFCC",
    "#FDCCFF",
    "#CDCCFF",
]

HelpCellsColors = [
    "#CCFFFF",  # 淡青色
    "#FFFFCC",  # 淡黄色
    "#CCFFCC",  # 淡绿色
    "#FFCCCC",  # 淡红色
    "#CCE6FF",  # 淡蓝色
    "#E8FFCC",  # 淡黄绿色
    "#FFCCFF",  # 淡粉色
    "#CCCCFF",  # 淡紫色
]
chosenBg = HelpCellsColors[5]
guessBg = HelpCellsColors[3]

strongColor = "#0096FF"
weakColor = "#FF9300"

linkGreenColor = "#00FA92"
linkRedColor = "#FF40FF"

groupColor = "#00AF00"

givenColor = "#0074B3"
# givenColor = "#102E76"
# givenColor = "#1941A3"

removeColor = "#FF2600"
chosenColor = "#00AF00"

AllCandColors = HelpCandsColors + [removeColor, chosenColor]


def blend_colors(color1, color2, alpha):

    r1, g1, b1 = int(color1[1:3], 16), int(color1[3:5], 16), int(color1[5:7], 16)
    r2, g2, b2 = int(color2[1:3], 16), int(color2[3:5], 16), int(color2[5:7], 16)

    r = int(r1 * (1 - alpha) + r2 * alpha)
    g = int(g1 * (1 - alpha) + g2 * alpha)
    b = int(b1 * (1 - alpha) + b2 * alpha)

    return f"#{r:02X}{g:02X}{b:02X}"
